/**
 * 
 */
package com.mcw.route;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import com.alibaba.fastjson.JSONObject;
import com.mcw.mybatisplus.bean.VerifyCode;
import com.mcw.mybatisplus.service.VerifyCodeServiceImpl;

/**
 * @author w.weizhen
 *
 */
@Controller
public class DataController {
    @Autowired
    private VerifyCodeServiceImpl verifyCodeService;
    
    @ResponseBody
    @RequestMapping("data/mybatisplus")
    public List<VerifyCode> menu()
    {
        List<VerifyCode> datas = verifyCodeService.queryAll();
        return datas;
    }
    
    
    @ResponseBody
    @RequestMapping("data/post")
    public String menu(@RequestBody JSONObject req)
    {
        System.err.println(req.toJSONString());
        
        
        return " ";
    }
    
}